home *** CD-ROM | disk | FTP | other *** search
- CHOOSE - Get single user choice from user
-
- This program waits for a user keypress from amongst the alphabetic characters
- passed on the call line. When the user presses one of the keys, the program
- terminates with ERRORLEVEL set to a value from 0 to n, corresponding to the
- characters passed, in reverse order.
-
- Call: CHOOSE ccccc
-
- Example:
-
- CHOOSE EDCBA
-
- If the user presses A, ERRORLEVEL is set to 0; B, set to 1, etc.
-
- Test ERRORLEVEL in descending order, e.g.
-
- CHOOSE CBA
- IF ERRORLEVEL 2 GOTO :CCHOSEN
- IF ERRORLEVEL 1 GOTO :BCHOSEN
- IF ERRORLEVEL 0 GOTO :ACHOSEN
-
- Entered by Dave Rich from MS-DOS Power User's Guide (correct codes)
-